﻿#ifndef USER_H
#define USER_H

#include <QString>

class User {
 public:
  enum Authority {
    NOT_LOGIN,
    SUPER_ADMIN,
    DEBUG_MODE,
  };

  explicit User(const QString& username = "未登录", const QString& password = "", const Authority& authority = NOT_LOGIN);

  QString username() const;
  void setUsername(const QString& username);

  QString password() const;
  void setPassword(const QString& password);

  Authority authority() const;
  void setAuthority(const Authority& authority);

 private:
  QString username_{"未登录"};
  QString password_{};
  Authority authority_{NOT_LOGIN};
};

#endif  // USER_H
